home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.19970626-19970929 / 000098_news@newsmaster….columbia.edu _Wed Jul 23 15:49:46 1997.msg < prev    next >
Internet Message Format  |  2020-01-01  |  2KB

  1. Return-Path: <news@newsmaster.cc.columbia.edu>
  2. Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.35.30])
  3.     by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id PAA29736
  4.     for <kermit.misc@watsun.cc.columbia.edu>; Wed, 23 Jul 1997 15:49:45 -0400 (EDT)
  5. Received: (from news@localhost)
  6.     by newsmaster.cc.columbia.edu (8.8.5/8.8.5) id PAA14389
  7.     for kermit.misc@watsun; Wed, 23 Jul 1997 15:49:45 -0400 (EDT)
  8. Path: news.columbia.edu!watsun.cc.columbia.edu!fdc
  9. From: fdc@watsun.cc.columbia.edu (Frank da Cruz)
  10. Newsgroups: comp.protocols.kermit.misc
  11. Subject: Re: \fFiles()
  12. Date: 23 Jul 1997 19:49:41 GMT
  13. Organization: Columbia University
  14. Lines: 38
  15. Message-ID: <5r5n8l$s6j$1@apakabar.cc.columbia.edu>
  16. References: <1997Jul22.190800@merlin.ecid.cig.mot.com>
  17. NNTP-Posting-Host: watsun.cc.columbia.edu
  18. Keywords: \fFiles()
  19. Xref: news.columbia.edu comp.protocols.kermit.misc:7376
  20.  
  21. In article <1997Jul22.190800@merlin.ecid.cig.mot.com>,
  22. Robert Cornell <cornellr@merlin.ecid.cig.mot.com> wrote:
  23. : I have been pulling my hair out trying to evaluate whether a file is a
  24. : file or a directory.
  25. : I think I've now got it down...
  26. You might have tried:
  27.  
  28.   IF DIRECTORY xxx <command>
  29.  
  30. Executes the <command> if xxx is a directory.
  31.  
  32. : [/home/cornellr] C-Kermit>mkdir dummy
  33. : [/home/cornellr] C-Kermit>echo \fFiles(dummy/*)
  34. : 0
  35. : [/home/cornellr] C-Kermit>echo \fFiles(dummy/.*)
  36. : 2
  37. : Can I safely assume this is a feature and that the fact that * dosen't match
  38. : . and .. is because:
  39. : [/home/cornellr] C-Kermit>echo \fFiles(*)
  40. : 27
  41. : [/home/cornellr] C-Kermit>echo \fFiles(.*)
  42. : 40
  43. : i.e. you don't want to see hidden(?) files.
  44. Right -- in UNIX, Kermit behaves as much as possible like the shell in this
  45. regard.  If you want to see hidden files you have to mention the dot.
  46.  
  47. : Further, how can I tell if its a directory/character special/link if I
  48. : haven't got read permissions on it (without using shell).
  49. C-Kermit is a cross-platform program, not just a UNIX one.  It doesn't go
  50. quite that far in distinguishing among weird UNIX filetypes.
  51.  
  52. - Frank